<template>
	<view class="">
		<swiper class="swiper" circular :indicator-dots="true" :autoplay="true" :interval="1000" :duration="500">
			<swiper-item v-for="(item,index) in swiperArr" :key="index">
				<image :src="item" mode="widthFix"></image>
			</swiper-item>
		</swiper>
		<view class="">
			<button @click="emitFn">子传父</button>
		</view>
	</view>

</template>

<script>
	
	export default {
		name: 'myswiper',
		data() {
			return {
				userinfo:{
					name:'张三'
				}
			}
		},
		props:['swiperArr'],
		methods:{
			emitFn(){
				// console.log(this);
				this.$emit('myevent',this.userinfo)
			}
		}

	}
</script>

<style scoped>
		
	swiper-item image{
		width: 100%;
		display: block;
	}
</style>
